﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Windows.Security.Cryptography.Core;

namespace HigLabo.Mime
{
    public class CryptographicKeyInfo
    {
        public String Base64Content { get; set; }
        public Boolean IsImportPrivateKey { get; private set; }
        public CryptographicPublicKeyBlobType PublicKeyBlobType { get; private set; }
        public CryptographicPrivateKeyBlobType PrivateKeyBlobType { get; private set; }

        private CryptographicKeyInfo(String base64Content)
        {
            Base64Content = base64Content;
        }
        public CryptographicKeyInfo(String base64Content, CryptographicPublicKeyBlobType publicKeyBlobType)
            : this(base64Content)
        {
            PublicKeyBlobType = publicKeyBlobType;
            IsImportPrivateKey = false;
        }
        public CryptographicKeyInfo(String base64Content, CryptographicPrivateKeyBlobType privateKeyBlobType)
            : this(base64Content)
        {
            PrivateKeyBlobType = privateKeyBlobType;
            IsImportPrivateKey = true;
        }
    }
}
